package com.zhang.sparkpublisher.controller;

import com.zhang.sparkpublisher.service.SparkPublisherService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

import java.util.Map;

/**
 * @title:
 * @author: zhang
 * @date: 2022/3/30 11:06
 */
@RestController
public class SparkPublisherController {
    @Autowired
    private SparkPublisherService sparkPublisherService;

    @RequestMapping("dauRealtime")
    public Map<String, Object> getDau(@RequestParam("td") String td) {
        Map<String, Object> result = sparkPublisherService.getDauService(td);
        return result;
    }

    @RequestMapping("test")
    public String test(){
        return "ok~~~~~~~~~~~~~~~~~~~";
    }
}
